import request from '@/utils/request'

// 创建查看当前所在房间
export function createUserCurrentRoom(data) {
  return request({
    url: '/jifenyuan/user-current-room/create',
    method: 'post',
    data: data
  })
}

// 更新查看当前所在房间
export function updateUserCurrentRoom(data) {
  return request({
    url: '/jifenyuan/user-current-room/update',
    method: 'put',
    data: data
  })
}

// 删除查看当前所在房间
export function deleteUserCurrentRoom(id) {
  return request({
    url: '/jifenyuan/user-current-room/delete?id=' + id,
    method: 'delete'
  })
}

// 获得查看当前所在房间
export function getUserCurrentRoom(id) {
  return request({
    url: '/jifenyuan/user-current-room/get?id=' + id,
    method: 'get'
  })
}

// 获得查看当前所在房间分页
export function getUserCurrentRoomPage(query) {
  return request({
    url: '/jifenyuan/user-current-room/page',
    method: 'get',
    params: query
  })
}

// 导出查看当前所在房间 Excel
export function exportUserCurrentRoomExcel(query) {
  return request({
    url: '/jifenyuan/user-current-room/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
